package com.example.demo.pojo;

import com.fasterxml.jackson.annotation.JsonFormat;
import org.springframework.format.annotation.DateTimeFormat;

import java.util.Date;

/**
 * 出-入库类
 */
public class OutBound {
    private int id;
    private int book_id;
    private int out_in_num;
    @JsonFormat(pattern = "yyyy-MM-dd")
    private Date out_in_date;
    private int out_in_state; //图书借出状态 1-借出,2-出库，3-预约，4-归还,5-入库

    private Books books;

    public OutBound() {

    }

    public OutBound(int book_id, int out_in_num, Date out_in_date, int out_in_state) {
        this.book_id = book_id;
        this.out_in_num = out_in_num;
        this.out_in_date = out_in_date;
        this.out_in_state = out_in_state;
    }

    @Override
    public String toString() {
        return "OutBound{" +
                "id=" + id +
                ", book_id=" + book_id +
                ", out_in_num=" + out_in_num +
                ", out_in_date=" + out_in_date +
                ", out_in_state=" + out_in_state +
                ", books=" + books +
                '}';
    }

    public Books getBooks() {
        return books;
    }

    public void setBooks(Books books) {
        this.books = books;
    }

    public int getOut_in_num() {
        return out_in_num;
    }

    public void setOut_in_num(int out_in_num) {
        this.out_in_num = out_in_num;
    }

    public int getId() {
        return id;
    }

    public void setId(int id) {
        this.id = id;
    }

    public int getBook_id() {
        return book_id;
    }

    public void setBook_id(int book_id) {
        this.book_id = book_id;
    }

    public Date getOut_in_date() {
        return out_in_date;
    }

    public void setOut_in_date(Date out_in_date) {
        this.out_in_date = out_in_date;
    }

    public int getOut_in_state() {
        return out_in_state;
    }

    public void setOut_in_state(int out_in_state) {
        this.out_in_state = out_in_state;
    }
}
